home *** CD-ROM | disk | FTP | other *** search
Wrap
/* v1.00 Interlace (for Image Engineer) Marko Seppänen marko.seppanen@wwnet.fi */ address IMAGEENGINEER Options results signal on error /* Setup a place for errors to go */ if arg()=0 then exit x=arg(1) parse var x pic sec . if sec == "" then do GET PRIMARY pic=result GET SECONDARY sec=result if sec=="" then do 'REQUEST "Choose an SECONDARY image!" "Sorry"' exit end PROJECT_INFO pic WIDTH picwidth=result PROJECT_INFO pic HEIGHT picheight=result PROJECT_INFO pic ZOOM piczoom=result PROJECT_INFO sec WIDTH secwidth=result PROJECT_INFO sec HEIGHT secheight=result end else do PROJECT_INFO pic WIDTH picwidth=result PROJECT_INFO pic HEIGHT picheight=result PROJECT_INFO pic ZOOM piczoom=result PROJECT_INFO sec WIDTH secwidth=result PROJECT_INFO sec HEIGHT secheight=result end if picwidth ~== secwidth | picheight ~== secheight then do 'REQUEST "Secondary and Primary images must be same size!" "Ok"' exit end if exists("ie:alpha/lacelines.alpha") == "0" then do 'REQUEST "Please download VE-Extras.lha" "Ok"' exit end OPEN "ie:alpha/lacelines.alpha" COLOUR lines=result PROJECT_SET lines ZOOM piczoom RESIZE lines picwidth picheight*2 TILE lacelines=result CLOSE lines SCALE pic picwidth picheight*2 FAST longpic=result MARK lacelines PRIMARY MARK longpic SECONDARY COMPOSITE 0 0 MIN lacepic=result CLOSE longpic SCALE sec secwidth secheight*2 FAST longsec=result MARK lacelines PRIMARY MARK longsec SECONDARY COMPOSITE 0 1 MIN lacesec=result CLOSE longsec CLOSE lacelines MARK lacepic PRIMARY MARK lacesec SECONDARY COMPOSITE 0 0 MAX final=result CLOSE lacepic CLOSE lacesec exit /*******************************************************************/ /* This is where control goes when an error code is returned by IE */ /* It puts up a message saying what happened and on which line */ /*******************************************************************/ error: if RC=5 then do /* Did the user just cancel us? */ IE_TO_FRONT LAST_ERROR 'REQUEST "'||RESULT||'"' exit end else do IE_TO_FRONT LAST_ERROR 'REQUEST "Error detected!!!'||D2C(10)||'Image Engineer error message is as follows'||D2C(10)||result||D2C(10)||'Script failed on line '||SIGL||'"' 'Doh!' exit end